<?php
	namespace Application\Home\Controller;
	use Application\Home\Model\Banner;
	use Application\Home\Model\Productcat;
	use Application\Home\Model\Chuanshi;
	class Index{
//		首页轮播图端口
		public function getBanner(){
			$bannerModel = new Banner();
			$banner = $bannerModel -> order('banner_sort asc')-> select();
			$data = json_encode($banner);
			echo $data;
		}
		
//		首页产品端口
		public function getProduct(){
			$productModel = new Productcat();
//			var_dump($productModel);exit;
			$product = $productModel-> select();
//			var_dump($product);exit;
			$data = json_encode($product);
			
			echo $data;
		}
//		首页传世端口
		public function chuanshi(){
			
			$Chuanshi = new Chuanshi();
			$Chuanshi = $Chuanshi-> order('sort asc') -> select();
			$data = json_encode($Chuanshi);
			echo $data;
		}
		
	}
?>